package com.tjut.oop.hol4;

public class Company {
	//定义属性员工数组
	private ColaEmployee[] colaEmployee;
	//定义属性月份
	private int month;

	public ColaEmployee[] getColaEmployee() {
		return colaEmployee;
	}

	public void setColaEmployee(ColaEmployee[] colaEmployee) {
		this.colaEmployee = colaEmployee;
	}

	public int getMonth() {
		return month;
	}

	public void setMonth(int month) {
		this.month = month;
	}

	public Company(ColaEmployee[] colaEmployee, int month) {
		super();
		this.colaEmployee = colaEmployee;
		this.month = month;
	}

	public void printfSalary() {

		// 循环打印员工本月份工资
		for (int i = 0; i < colaEmployee.length; i++) {
			System.out.println(colaEmployee[i].getStaffNam() 
					+ "本月的工资为：" + colaEmployee[i].getSalary(month));
		}
	}
}
